home *** CD-ROM | disk | FTP | other *** search
/ ftp.mactech.com 2010 / ftp.mactech.com.tar / ftp.mactech.com / machack / Hacks97 / WarriorsProgress.sit / Warrior’s Progress / source code / Source / Libraries / Miscellany / A5.h < prev    next >
Text File  |  1997-06-28  |  392b  |  38 lines

  1. // A5.h
  2.  
  3. #ifndef A5_h
  4. #define A5_h
  5.  
  6. #ifndef Registers_h
  7. #include "Registers.h"
  8. #endif
  9.  
  10. #if GENERATINGCFM
  11.  
  12.     class A5
  13.       {
  14.         public:
  15.             void Restore() const        {}
  16.       };
  17.  
  18. #else
  19.  
  20.     class A5
  21.       {
  22.         private:
  23.             void *const a5;
  24.         
  25.         public:
  26.             A5()
  27.               : a5( RegisterA5() )
  28.               {}
  29.             
  30.             void Restore() const    { SetRegisterA5( a5 ); }
  31.             
  32.             void *Address() const    { return a5; }
  33.       };
  34.  
  35. #endif
  36.  
  37. #endif
  38.